package org.study.javafx.demo11.model;

import javafx.beans.property.SimpleStringProperty;

/**
 * 作用描述
 *
 * @author doveylovey
 * @version v1.0.0
 * @email 1135782208@qq.com
 * @date 2024年07月28日
 */
public class ChinaRegion {
    // 属性都是SimpleStringProperty的，SimpleStringProperty是JavaFX中的一个类，它用于将字符串属性与JavaFX控件进行绑定
    private final SimpleStringProperty provinceId;
    private final SimpleStringProperty provinceName;
    private final SimpleStringProperty cityId;
    private final SimpleStringProperty cityName;
    private final SimpleStringProperty areaId;
    private final SimpleStringProperty areaName;

    public ChinaRegion(String provinceId, String provinceName, String cityId, String cityName, String areaId, String areaName) {
        this.provinceId = new SimpleStringProperty(provinceId);
        this.provinceName = new SimpleStringProperty(provinceName);
        this.cityId = new SimpleStringProperty(cityId);
        this.cityName = new SimpleStringProperty(cityName);
        this.areaId = new SimpleStringProperty(areaId);
        this.areaName = new SimpleStringProperty(areaName);
    }

    public String getProvinceId() {
        return provinceId.get();
    }

    public SimpleStringProperty provinceIdProperty() {
        return provinceId;
    }

    public void setProvinceId(String provinceId) {
        this.provinceId.set(provinceId);
    }

    public String getProvinceName() {
        return provinceName.get();
    }

    public SimpleStringProperty provinceNameProperty() {
        return provinceName;
    }

    public void setProvinceName(String provinceName) {
        this.provinceName.set(provinceName);
    }

    public String getCityId() {
        return cityId.get();
    }

    public SimpleStringProperty cityIdProperty() {
        return cityId;
    }

    public void setCityId(String cityId) {
        this.cityId.set(cityId);
    }

    public String getCityName() {
        return cityName.get();
    }

    public SimpleStringProperty cityNameProperty() {
        return cityName;
    }

    public void setCityName(String cityName) {
        this.cityName.set(cityName);
    }

    public String getAreaId() {
        return areaId.get();
    }

    public SimpleStringProperty areaIdProperty() {
        return areaId;
    }

    public void setAreaId(String areaId) {
        this.areaId.set(areaId);
    }

    public String getAreaName() {
        return areaName.get();
    }

    public SimpleStringProperty areaNameProperty() {
        return areaName;
    }

    public void setAreaName(String areaName) {
        this.areaName.set(areaName);
    }
}
